#define _CRT_SECURE_NO_WARNINGS  1

#include<stdio.h>
#include<string.h>


void reverse(char arr[],int sz)
{
	char* left = arr;
	char tmp = 0;
	char* right = arr + sz-1;
	while (left <= right)
	{
		tmp = *left;
		*left = *right;
		*right = tmp;
		left++;
		right--;
	}
}

int main()
{
	char arr[] = "abcdef";
	int sz = strlen(arr);
	reverse(arr,sz);
	int i = 0;
	for (i = 0; i < sz; i++)
	{
		printf("%c ", arr[i]);
	}
	return 0;
}

